package com.qinggeng.project.system.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.qinggeng.framework.aspectj.lang.annotation.Excel;
import lombok.Data;
import com.qinggeng.framework.web.domain.BaseEntity;

/**
 * 用户位置对象 user_location
 * 
 * @author qinggeng
 * @date 2020-06-26
 */
@Data
public class UserLocation extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 骑手ID */
    @Excel(name = "骑手ID")
    private Long userId;

    /** 精度 */
    @Excel(name = "精度")
    private Float lng;

    /** 纬度 */
    @Excel(name = "纬度")
    private Float lat;

    //距离
    private String distance;


    public UserLocation(Long userId, Float lng, Float lat) {
        this.userId = userId;
        this.lng = lng;
        this.lat = lat;
    }

    public UserLocation(){}

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Float getLng() {
        return lng;
    }

    public void setLng(Float lng) {
        this.lng = lng;
    }

    public Float getLat() {
        return lat;
    }

    public void setLat(Float lat) {
        this.lat = lat;
    }

    public String getDistance() {
        return distance;
    }

    public void setDistance(String distance) {
        this.distance = distance;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("userId", getUserId())
            .append("lng", getLng())
            .append("lat", getLat())
            .append("createTime", getCreateTime())
            .toString();
    }
}
